<!doctype html>
<html>
<head>
  <meta charset="utf-8">
  <title>系统配置</title>
  <meta name="renderer" content="webkit">
  <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
  <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
  <link rel="stylesheet" type="text/css" href="__ADMIN__/layui/css/layui.css" media="all">
  <link rel="stylesheet" type="text/css" href="__ADMIN__/bootstrap/css/bootstrap.css" media="all">
  <link rel="stylesheet" type="text/css" href="__ADMIN__/global.css" media="all">
  <link rel="stylesheet" type="text/css" href="__ADMIN__/css/personal.css" media="all">
  <link rel="stylesheet" type="text/css" href="__ADMIN__/css/page.css" media="all">
  <script type="text/javascript" src="__ADMIN__/jedate/jquery-1.7.2.js"></script>
</head>
<body>
  <blockquote class="layui-elem-quote mylog-info-tit">
    <ul class="layui-tab-title">
        <a href="/admin/system/index"><li class="layui-btn"><i class="layui-icon"></i>返回</li></a>
        <a href="/admin/system/add"><li class="layui-btn"><i class="layui-icon"></i>添加配置项</li></a>
    </ul>
</blockquote>
  <div class="layui-tab layui-tab-card">
  <ul class="layui-tab-title">
    <li <if condition="$groupid eq 0">class="layui-this"<else/>class=""</if>> <a href="{:U('config',array('groupid'=> 0))}">全部</a></li> 
    <foreach name='configgroup' item='v'>
       <li <if condition="$key eq $groupid">class="layui-this"<else/>class=""</if>><a href="{:U('config',array('groupid'=> $key))}">{$v}</a>&nbsp;</li>
    </foreach>
  </ul>
  <div class="layui-tab-content">
    <div class="layui-tab-item layui-show">
      <table class="layui-table">
        <colgroup>
          <col width="150">
          <col width="200">
          <col>
        </colgroup>
        <thead>
          <tr>
            <th>编号</th>
            <th>名称</th>
            <th>标题</th>
            <th>分组</th>
            <th>类型</th>
            <th>操作</th>
          </tr> 
        </thead>
        <tbody>
          <foreach name='vlist' item='v'>
          <tr>
            <td>{$v.id}</td>
            <td class="aleft">{$v.name}</td>
            <td >{$v.title}</td>
            <td>{$v.groupid|get_item_value='configgroup',###}</td>                
            <td>{$v.typeid|get_item_value='configtype',###}</td>
            <td>
              <a href="{:U('edit',array('id' => $v['id']))}"><button class="layui-btn"><i class="layui-icon">&#xe642;</i></button></a>
              <a href="{:U('del', array('id' => $v['id']))}"><button class="layui-btn"><i class="layui-icon">&#xe640;</i></button></a>
            </td>
          </tr>
          </foreach>
        </tbody>
      </table>
    </div>
    <div id="page" class="green-black">{$page}</div>
  </div>
</div>

 
<script src="__ADMIN__/layui/layui.js" charset="utf-8"></script>
<script>
layui.use('element', function(){
  var $ = layui.jquery
  ,element = layui.element(); //Tab的切换功能，切换事件监听等，需要依赖element模块
});
layui.use('form', function(){
  var form = layui.form();
  });
</script>

</body>
</html>